<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>案例-Android机器人</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        body {
            background-color: #ccc;
        }

        .content {
            width: 500px;
            height: 500px;
            border: 1px solid red;
            margin: 50px auto;
        }

        .an-header {
            width: 250px;
            height: 125px;
            background-color: darkgreen;
            margin: 10px auto;
            /* 添加圆角 */
            border-radius: 125px 125px 0 0;
            position: relative;
        }

        /* 使用伪元素添加眼睛 */
        .an-header::before,.an-header::after {
            content: "";
            position: absolute;
            width: 20px;
            height: 20px;
            border-radius: 10px;
            background-color: #fff;
            bottom: 40px;
        }

        .an-header::before {
            left: 70px;
        }

        .an-header::after {
            right: 70px;
        }

        .an-body {
            width: 250px;
            height: 250px;
            background-color: darkgreen;
            border-radius: 0 0 20px 20px;
            margin: 0 auto;
            position: relative;
        }

        .an-body::before, .an-body::after {
            content: "";
            position: absolute;
            background-color: darkgreen;
            width: 30px;
            height: 180px;
            border-radius: 10px;
            top: 20px;
        }

        .an-body::before {
            left: -40px;
        }

        .an-body::after {
            right: -40px;
        }

        .an-footer {
            width: 250px;
            height: 100px;
            margin: 0 auto;
            position: relative;
        }

        .an-footer::before, .an-footer::after {
            content: "";
            position: absolute;
            background-color: darkgreen;
            width: 30px;
            height: 90px;
            border-radius: 0 0 10px 10px;
            top: 0;
        }

        .an-footer::before {
            left: 50px;
        }

        .an-footer::after {
            right: 50px;
        }
    </style>
</head>
<body>
    <div class="content">
        <div class="an-header"></div>
        <div class="an-body"></div>
        <div class="an-footer"></div>
    </div>
</body>
</html>